package com.fz.us.admin.base.entity.parent;

import com.fz.us.admin.base.bean.BaseEnumManager;
import com.fz.us.admin.base.entity.BaseEntity;

import javax.persistence.Column;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.MappedSuperclass;

/**
 * 实体类 - 名称+拼音 基类
 * ============================================================================
 * 版权所有 2016 。
 *
 * @author fallenpanda
 * @version 1.0 2016-07-21 。
 * ============================================================================
 */
@MappedSuperclass
public class NameEntity extends BaseEntity {

    private static final long serialVersionUID = 7509174365162044880L;

    /**
     * 文档状态
     */
    protected BaseEnumManager.StateEnum state;
    /**
     * 名称
     */
    protected String name;
    /**
     * 拼音首字母
     */
    protected String pinYinHead;
    /**
     * 拼音
     */
    protected String pinYin;

    @Column(nullable = false)
    @Enumerated(EnumType.STRING)
    public BaseEnumManager.StateEnum getState() {
        return state;
    }

    public void setState(BaseEnumManager.StateEnum state) {
        this.state = state;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPinYinHead() {
        return pinYinHead;
    }

    public void setPinYinHead(String pinYinHead) {
        this.pinYinHead = pinYinHead;
    }

    public String getPinYin() {
        return pinYin;
    }

    public void setPinYin(String pinYin) {
        this.pinYin = pinYin;
    }

}
